/*package cn.school.util;

import cn.school.service.StudentService;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

final public class SpringUtil {
    private  static ApplicationContext ac;
    private SpringUtil(){

    }
    static{
        ac = new ClassPathXmlApplicationContext("app*.xml");
    }
    public static ApplicationContext getApplicationContext(){
        return ac;
    }
    public static Object getBean(String id){
        return ac.getBean(id);
    }
    public static <T> T getBean(Class<T> c){
        return ac.getBean(c);
    }

    public static void main(String[] args) {
        StudentService s=SpringUtil.getBean(StudentService.class);

    }
}*/
